#!/bin/bash
tempdir=`dirname $1`
nice mencoder -ofps 25 -of lavf -lavfopts format=mp4 \
  -af lavcresample=44100 \
  -alang de \
  -vf-add harddup \
  -vf-add scale=320:-10 \
  -vf-add crop=720:480:0:0 \
  -oac lavc -ovc lavc \
  -lavcopts aglobal=1:vglobal=1:acodec=aac:abitrate=128:vcodec=mpeg4:vbitrate=576:keyint=25 \
  -lavfopts i_certify_that_my_video_stream_does_not_use_b_frames \
  -o "$tempdir/tmp.mp4" $@
